package com.juntuo.service.impl;

import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.juntuo.entity.Role;
import com.juntuo.entity.User;
import com.juntuo.service.RoleService;
import com.juntuo.service.UserService;
import com.juntuo.service.helper.CommonServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 简介：
 * 作者：Jason (chenxj@hadlinks.com)
 * 时间：2018/3/17 14:18
 */
@Service
public class RoleServiceImpl extends CommonServiceImpl<Role> implements RoleService {


    @Override
    public PageInfo<Role> findPagedRole(int pageNumber, int pageSize) {
        PageHelper.startPage(pageNumber,pageSize);
        List<Role> roles=super.selectAll();
        PageInfo pageInfo= new PageInfo(roles);
        return pageInfo;
    }
}
